# Author:	gong_libin
# Date:		2016_06_01

CC = gcc
CFLAGS ?= -Wall -fPIC

GLB_ENV ?= $(shell pwd)/../..
GLB_INC ?= $(GLB_ENV)/inc
GLB_SRC ?= $(GLB_ENV)/src
GLB_OBJ ?= $(GLB_SRC)/GlbObj

OBJECTS =				\
	GlbCode.o			\
	GlbUtil.o

all: $(OBJECTS) install

$(OBJECTS): %.o: %.c
	$(CC) -c $(CFLAGS) -I$(GLB_INC) $< -o $@

install:
	cp $(OBJECTS) $(GLB_OBJ)/.

clean:
	rm -rf $(OBJECTS)
